var slideDuration = 0.3;

function menuSlideDown(parentElement, idElement) {
	new Effect.SlideDown(idElement, {duration:slideDuration});
	document.getElementById(parentElement).onclick = function(){menuSlideUp(parentElement, idElement);};
}

function menuSlideUp(parentElement, idElement) {
	new Effect.SlideUp(idElement, {duration:slideDuration});
	document.getElementById(parentElement).onclick = function(){menuSlideDown(parentElement, idElement);};
}